package io.renren.modules.jxgkphone.service.Impl;

import io.renren.modules.jxgkphone.dao.CourseDateMapper;
import io.renren.modules.jxgkphone.entity.CourseDate;
import io.renren.modules.jxgkphone.service.CourseDateService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class CourseDateServiceImpl implements CourseDateService {
    @Autowired
    CourseDateMapper courseDateMapper;
    @Override
    public CourseDate getDayInfo(String curDate) {
        return courseDateMapper.getCourseDateByCurDate(curDate);
    }
    @Override
    public void  insertCourseDate(String date, String year, String term, String week, String day){
        courseDateMapper.insertCourseDate(date, year, term, week, day);
    }
    @Override
    public List<CourseDate> getDaysByTermAndWeek(String year, String term, String week){
        return  courseDateMapper.getDaysByTermAndWeek(year, term, week);
    }
}
